#ifndef PBVP_MOLSURFACEPLUGIN_H
#define PBVP_MOLSURFACEPLUGIN_H

#include <QAction>
#include <QProgressBar>
#include "../toolplugin.h"

namespace PBVP {
	class DataManager;
	class RenderManager;
	class MolSurfaceControl;
	///
	class MolSurfacePlugin : public QObject, public ToolPlugin
	{
		Q_OBJECT
		Q_INTERFACES(PBVP::ToolPlugin)
	public:
		///
		MolSurfacePlugin();
		///
		~MolSurfacePlugin();
		///
		virtual QString description() const {
			return QString("Construct molecular surface from protein data");
		} 
		/// 
		virtual void initialize(MainInterface* mainInterface);
		///
		virtual bool isSupported(DataNode* pNode);
		///
		virtual QAction* getToolAction() {
			return molSurfAction;
		}

		typedef enum {
			MOL_PROTEIN = 0,
			MOL_CHAIN,
			MOL_LIGAND
		} SurfaceMode;

	public slots:
		void constructSurface();

	private:
		QAction *molSurfAction;
		QProgressBar *progressBar;

		DataManager *m_pDataManager;
		RenderManager *m_pRenderManager;

		MolSurfaceControl *m_pControl;
	};
}
#endif // MOLSURFACEPLUGIN_H
